package kandl.automation.reporting.testrail.model;

import org.codehaus.jackson.annotate.JsonCreator;
import org.codehaus.jackson.annotate.JsonIgnoreProperties;
import org.codehaus.jackson.annotate.JsonProperty;

import java.util.Arrays;
import java.util.List;

@JsonIgnoreProperties(ignoreUnknown = true)
public class TestRailEntry {

    private final List<TestRailRun> runs;

    @JsonCreator
    public TestRailEntry(@JsonProperty("runs") TestRailRun... runs) {
        this.runs = Arrays.asList(runs);
    }

    public List<TestRailRun> getRuns() {
        return runs;
    }
}
